<!-- 分享列表 -->
<template>
	<view class="_page">
		<scroll-view scroll-y="true" show-scrollbar="true" scroll-top="0">
			<view v-if="friendList == 0" class="no-list">
				<image class="technician-avatar1" src="../../static/images/no_one.png" mode="aspectFill"></image>
				<text>暂无好友列表信息~</text>
			</view>
			<view class="list" v-for="(item,index) in friendList" :key="index" v-else>
				<view class="list-left">
					<image class="list-left-avatar" :src="item.avatar" mode="aspectFill"></image>
					<text class="list-left-name">{{item.nickName}}</text>
				</view>

			<!-- 	<view class="list-right">
					<image src="../../static/images/huangguan1.png" mode="" class="list-right-img"></image>
					<text class="list-right-name">一级分销员</text>
				</view> -->
			</view>
		</scroll-view>
	</view>
</template>

<script>
	import {sharePage} from '@/api/index.js';
	import config from '@/config/index';
	export default {
		data() {
			return {
				friendList:[],//好友列表
			}
		},
		onLoad() {
			this.getFriendList()
		},
		methods: {
			getFriendList(){
				let _that = this
				sharePage().then(re =>{
					_that.friendList = re
					console.log(re,_that.friendList)
				}).catch(re=>{
					console.log(re);
				});
			},
		}
	}
</script>

<style>
	._page {
		width: 100%;
		margin-top: 24rpx;
	}
	.no-list{
		display: flex;
		flex-direction: column;
		align-items: center;
	}
	.no-list image{
		width:200rpx;
		height:200rpx;
	}
	.list {
		height: 160rpx;
		width: 100%;
		background-color: #FFFFFF;
		display: flex;
		flex-direction: row;
		justify-content: space-between;
		align-items: center;
		margin-bottom: 2rpx;

	}

	.list-left {
		margin-left: 26rpx;
		display: flex;
		flex-direction: row;
		justify-content: center;
		align-items: center;

	}

	.list-left-avatar {
		width: 100rpx;
		height: 100rpx;
	}

	.list-left-name {
		margin-left: 18rpx;
		color: rgba(62, 62, 62, 1);
		font-size: 32rpx;
		text-align: left;
		font-family: PingFangSC-bold;
		font-weight: bold;
	}

	.list-right {
		display: flex;
		flex-direction: row;
		justify-content: center;
		align-items: center;
		padding: 0 38rpx 0 0;
	}
	
	.list-right-img{
		width: 60rpx;
		height: 60rpx;
	}
	
	.list-right-name{
		margin-left: 24rpx;
		opacity: 0.9;
		color: rgba(166, 117, 57, 1);
		font-size: 26rpx;
		font-family: PingFangSC-regular;
	}
</style>
